<%@ page language="java" import="java.util.*" pageEncoding="UTF-8"%>
<%@taglib prefix="s" uri="/struts-tags"%>
<%
	String path = request.getContextPath();
	String basePath = request.getScheme() + "://"
			+ request.getServerName() + ":" + request.getServerPort()
			+ path + "/";
%>
<html>
<head>
<base href="<%=basePath%>" />
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<title>模板列表</title>
<script type='text/javascript' src='js/jquery-1.4.2.min.js'></script>
<script type='text/javascript' src='js/jquery.validate.min.js'></script>
<script type='text/javascript' src='js/common.js'></script>
<script type='text/javascript' src='js/jquery-ui-1.7.3.custom.min.js'></script>
<script type='text/javascript' src='ckeditor/ckeditor.js'></script>
 <link href="style/ui-lightness/jquery-ui-1.7.3.custom.css" rel="stylesheet" type="text/css">
<link href="manage/manage.css" rel="stylesheet" type="text/css">
<script type="text/javascript"> 
   function  submitForm() {
	   var s = CKEDITOR.instances.content.getData();
	   if (s=="") {
		   alert("请输入内容");
		   return;
	   }
	   $("#articleForm").submit();
   }
   
</script>
</head>
<body style="margin:0px; text-align:center;font-size:12px;" bgcolor="#F1F1F1" >
<div id="top">
 	<!-- 头部-->
 	<%@include file="mainTop.jsp"%>
</div>
<div id="top2"></div>

<!-- 中间-->
<div id="main1">
<!-- 左边-->
 <%@include file="mainLeft.jsp"%>
 <div class="mainr2">
 <s:form action="articleAction!update.action" method="post" id="articleForm">
<table width="789" height="500" border="0" cellpadding="0" cellspacing="0" bgcolor="#F1F1F1">
	<tr>
		<s:if test="hasErrors()">
			<td style="color: red;height: 30px;" align="center" colspan="10">
				<s:actionerror/>
			</td>
		</s:if>
		<s:if test="hasActionMessages()">
			<td style="color: green;height: 30px;" align="center" colspan="10">
				<s:actionmessage/>
			</td>
		</s:if>
	</tr>
  <tr>
    <td height="500" align="left" valign="top">
	<table width="788" height="70" border="0" cellpadding="0" cellspacing="0" style="border-bottom:1px solid #DBDBDB; border-left:1px solid #DBDBDB;  " >
      <tr style="font-size:12px">
      	<s:if test="type==1">
        	<td width="112" height="22" align="center" bgcolor="#FFFFFF" style="border-top:1px solid #DBDBDB; border-right:1px solid #DBDBDB;" >易彩通简介</td>
      	</s:if>
      	<s:else>
      		<td width="110" align="center"   background="images/line3.jpg" style="border:1px solid #DBDBDB;"><a href="articleAction!show.action?type=1">易彩通简介</a></td>
      	</s:else>
        <td width="7" style="border-bottom:1px solid #DBDBDB;">&nbsp;</td>
        
        <s:if test="type==2">
        	<td width="112" height="22" align="center" bgcolor="#FFFFFF" style="border-top:1px solid #DBDBDB; border-right:1px solid #DBDBDB;" >诚聘英才</td>
      	</s:if>
      	<s:else>
      		<td width="110" align="center"   background="images/line3.jpg" style="border:1px solid #DBDBDB;"><a href="articleAction!show.action?type=2">诚聘英才</a></td>
      	</s:else>
        <td width="7" style="border-bottom:1px solid #DBDBDB;">&nbsp;</td>
    
    	 <s:if test="type==3">
        	<td width="112" height="22" align="center" bgcolor="#FFFFFF" style="border-top:1px solid #DBDBDB; border-right:1px solid #DBDBDB;" >联系我们</td>
      	</s:if>
      	<s:else>
      		<td width="110" align="center"   background="images/line3.jpg" style="border:1px solid #DBDBDB;"><a href="articleAction!show.action?type=3">联系我们</a></td>
      	</s:else>
        <td width="7" style="border-bottom:1px solid #DBDBDB;">&nbsp;</td>
        
        <s:if test="type==4">
        	<td width="112" height="22" align="center" bgcolor="#FFFFFF" style="border-top:1px solid #DBDBDB; border-right:1px solid #DBDBDB;" >法律声明</td>
      	</s:if>
      	<s:else>
      		<td width="110" align="center"   background="images/line3.jpg" style="border:1px solid #DBDBDB;"><a href="articleAction!show.action?type=4">法律声明</a></td>
      	</s:else>
        <td width="7" style="border-bottom:1px solid #DBDBDB;">&nbsp;</td>
    	
    	<s:if test="type==5">
        	<td width="112" height="22" align="center" bgcolor="#FFFFFF" style="border-top:1px solid #DBDBDB; border-right:1px solid #DBDBDB;" >隐私条款</td>
      	</s:if>
      	<s:else>
      		<td width="110" align="center"   background="images/line3.jpg" style="border:1px solid #DBDBDB;"><a href="articleAction!show.action?type=5">隐私条款</a></td>
      	</s:else>
        <td width="7" style="border-bottom:1px solid #DBDBDB;">&nbsp;</td>
    	
    	<s:if test="type==6">
        	<td width="112" height="22" align="center" bgcolor="#FFFFFF" style="border-top:1px solid #DBDBDB; border-right:1px solid #DBDBDB;" > 安全保障 </td>
      	</s:if>
      	<s:else>
      		<td width="110" align="center"   background="images/line3.jpg" style="border:1px solid #DBDBDB;"><a href="articleAction!show.action?type=6"> 安全保障 </a></td>
      	</s:else>
		<td width="7" style="border-bottom:1px solid #DBDBDB;">&nbsp;</td>      	
      	
      	<s:if test="type==5">
        	<td width="112" height="22" align="center" bgcolor="#FFFFFF" style="border-top:1px solid #DBDBDB; border-right:1px solid #DBDBDB;" >客户服务协议</td>
      	</s:if>
      	<s:else>
      		<td width="110" align="center"   background="images/line3.jpg" style="border:1px solid #DBDBDB;"><a href="articleAction!show.action?type=7">客户服务协议</a></td>
      	</s:else>
        <td width="250px;" style="border-bottom:1px solid #DBDBDB;">&nbsp;</td>
      </tr>
	  
      <tr>
      	<td colspan="14"><input type="hidden" name="type" value="${article.id}"/>
	      <textarea cols="80" id="content" name="content" rows="10">${article.content}
	     </textarea>
      	</td>	
      </tr>
      <tr>
      	<td colspan="12" height="30px;" align="center">
      		<input type="button" value="  更新  " onclick="submitForm();" />
      	</td>
      </tr>
      <tr>
      	<td colspan="12" height="30px;">&nbsp;</td>
      </tr>
        </table>
      </td>
      </tr>
    </table> 
    </s:form>
 </div>
</div>

  <script type="text/javascript">
    CKEDITOR.replace( 'content',
     {
      skin : 'kama',
      language : 'zh-cn'
     });
   </script>

</body>
</html>
